<@override name="head">
    <#assign sec=JspTaglibs["/WEB-INF/tags/security.tld"]>
<title>广告投放系统</title>
<link rel="stylesheet" href="${ctx}/assets/css/dashboard_advertiser.css"/>
<link rel="stylesheet" href="${ctx}/assets/css/daterangepicker.css"/>
<link rel="stylesheet" href="${ctx}/assets/css/font-awesome.min.css"/>

<script type="text/javascript" src="${ctx}/assets/js/lib/moment.min.js"></script>
<script type="text/javascript" src="${ctx}/assets/js/lib/jquery.daterangepicker.js"></script>
<script type="text/javascript" src="${ctx}/assets/js/lib/highcharts.js"></script>
<script type="text/javascript" src="${ctx}/assets/js/lib/bootstrap.min.js"></script>
<script type="text/javascript" src="${ctx}/assets/js/lib/bootbox.js"></script>
<input type="hidden" id="hasRight" value="${hasRight?string('true','false')}"/>
<script type="text/javascript" src="${ctx}/assets/js/lib/Chart.min.js"></script>
<script type="text/javascript" src="${ctx}/assets/js/advertiser/dashboard.js"></script>
</@override>
<@override name="body">
<div id=content_bg>
    <#include "/main/home/common.ftl"/>
    <div id="pagecontent">
        <div id="content">
            <div id="navDiv">
                <ul id="navDiv_ul">
                    <li><i class="icon-home" style="color:white;"></i></li>
                    <li class="navDiv_currentLi" style="color:white;">首页</li>
                </ul>
            </div>
            <div class="pie-charts">
                <div class="pie-chart-item glass">
                    <i class="chart-icon ion-eye"></i>
                    <div class="description">
                        <div class="description-title">曝光数</div>
                        <div class="description-stats" id="bgsDiv">${compareMap.totalImpression!}</div>
                    </div>
                </div>
                <div class="pie-chart-item glass">
                    <i class="chart-icon ion-mouse"></i>
                    <div class="description">
                        <div class="description-title">点击数</div>
                        <div class="description-stats" id="djsDiv">${compareMap.totalClick!}</div>
                    </div>
                </div>
                <div class="pie-chart-item glass">
                    <i class="chart-icon ion-social-yen"></i>
                    <div class="description">
                        <div class="description-title">账户余额</div>
                        <div class="description-stats" id="balanceSpan">${compareMap.balance!}</div>
                    </div>
                </div>
                <div class="pie-chart-item glass">
                    <i class="chart-icon ion-social-yen-outline"></i>
                    <div class="description">
                        <div class="description-title">已花费</div>
                        <div class="description-stats" id="costSpan">0.00</div>
                    </div>
                </div>
                <@sec.authorize access="hasAnyRole('ROLE_agent_adgroup,ROLE_MANAGER')">
                    <input type="hidden" id="isShowRight" value="0"/>
                </@sec.authorize>
            </div>

            <div class="canvas-div glass">
                <div class="canvas-holder">
                    <div class="traffic-text">
                        <span>总流量</span>
                        <i id="traffic-total"></i>
                    </div>
                    <canvas id="chart-area" width="218px" height="218px"></canvas>
                </div>
            </div>

            <div id="dashboard_diagram" class="index-table glass">
                <div class="tools">
                    <div class="item">
                        <label class="input-label-other">设备类型：</label>
                        <select class="input-text" id="sourceSelect">
                            <#list sourceList as item>
                                <option value="${item.key}">${item.value}</option>
                            </#list>
                        </select>
                    </div>
                    <div class="item search">
                        <div class="select2-search">
                            <input type="text" class="select2-input" id="mediaText">
                        </div>
                    </div>
                </div>
                <table class="table" id="maintable">
                    <thead class="thead">
                    <tr>
                        <th>名称</th>
                        <th>流量</th>
                        <#if hasRight==true??>
                            <th>曝光数</th>
                            <th>点击数</th>
                            <th>花费</th>
                        </#if>
                        <th>更新时间</th>
                    </tr>
                    </thead>
                    <tbody class="tbody">
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>
</@override>
<@extends name="/common/simple.ftl" />